package com.tcfvic.client;

import java.util.Date;
import java.util.List;

import com.google.gwt.user.client.rpc.AsyncCallback;
import com.tcfvic.client.pojos.Course;
import com.tcfvic.client.pojos.Courselevel;
import com.tcfvic.client.pojos.Employmentdetails;
import com.tcfvic.client.pojos.Employmentstatus;
import com.tcfvic.client.pojos.Expense;
import com.tcfvic.client.pojos.Fundingsource;
import com.tcfvic.client.pojos.Industry;
import com.tcfvic.client.pojos.Jsp;
import com.tcfvic.client.pojos.Logs;
import com.tcfvic.client.pojos.Person;
import com.tcfvic.client.pojos.Personcourse;
import com.tcfvic.client.pojos.Personcoursefundingsource;
import com.tcfvic.client.pojos.Personjsp;
import com.tcfvic.client.pojos.Qualification;
import com.tcfvic.client.pojos.Rto;
import com.tcfvic.client.pojos.Workercompany;
import com.tcfvic.client.pojosInternal.AvailableFunding;

public interface PersonServiceAsync {

	void getAllPersonDetails(AsyncCallback<List<Person>> callback);

	void getPersonDetails(int id, AsyncCallback<Person> callback);

	void savePersonDetails(Person details, AsyncCallback<Person> callback);

	void getAllCompanies(AsyncCallback<List<Workercompany>> callback);

	void getCompanyDetails(int id, AsyncCallback<Workercompany> callback);

	void saveCompanyDetails(Workercompany company, AsyncCallback<Void> callback);

	void saveFundingSourceDetails(Fundingsource company,
			AsyncCallback<Void> callback);

	void getFundingSourceDetails(int id, AsyncCallback<Fundingsource> callback);

	void getPersonFundingSources(int personId,
			AsyncCallback<List<Fundingsource>> callback);

	// void getPersonCoursesByFundingID(int fundingId,
	// AsyncCallback<List<Personcourse>> callback);

	void getAllFundingSources(AsyncCallback<List<Fundingsource>> callback);

	void getAllTraining(AsyncCallback<List<Course>> callback);

	void getTrainingDetails(int id, AsyncCallback<Course> callback);

	void saveTrainingDetails(Course company, AsyncCallback<Void> callback);

	void getPersonCourseDetails(int personId,
			AsyncCallback<List<Personcourse>> callback);

	void getPersonCourseFundingSource(int personId,
			AsyncCallback<List<Personcoursefundingsource>> callback);
	
	void getAllExpenses(Integer personId, AsyncCallback<List<Expense>> callback);
	void saveExpense(Expense expense, AsyncCallback<Void> callback);
	void saveExpenses(List<Expense> expenses, boolean deleteFirst, AsyncCallback<Void> callback);
	
	void getExpense(int id, AsyncCallback<Expense> callback);

	void getAllCourseLevels(AsyncCallback<List<Courselevel>> callBack);
	void saveCourseLevel(Courselevel courseLevel, AsyncCallback<Void> callback);

	void getAllRTOs(AsyncCallback<List<Rto>> callback);
	void getRTO(int id, AsyncCallback<Rto> callback);
	void saveRTO(Rto rto, AsyncCallback<Void> callback);

	void getAvailableAmounts(int personId, AsyncCallback<List<AvailableFunding>> callback);

	void getAllJSPs(AsyncCallback<List<Jsp>> callback);
	void getJSPDetails(int id, AsyncCallback<Jsp> callback);
	void saveJSPDetails(Jsp jsp, AsyncCallback<Void> callback);

	void getAllQualifications(AsyncCallback<List<Qualification>> callback);
	void saveQualification(Qualification qualification,
			AsyncCallback<Void> callback);

	void getAllSuburbs(AsyncCallback<List<String>> callback);

	void deletePerson(int id, AsyncCallback<Void> callback);

	void deleteCompany(int id, AsyncCallback<Void> callback);

	void deleteFundingSource(int id, AsyncCallback<Void> callback);

	void deleteCourse(int id, AsyncCallback<Void> callback);

	void deleteJsp(int id, AsyncCallback<Void> callback);

	void deleteIndustry(int id, AsyncCallback<Void> callback);

	void deleteRto(int id, AsyncCallback<Void> callback);

	void getEmploymentStatus(int personId,
			AsyncCallback<List<Employmentstatus>> callback);

	void saveEmploymentStatus(List<Employmentstatus> expenses, boolean deleteFirst,
			AsyncCallback<Void> callback);

	void truncateDatabase(AsyncCallback<Void> callback);

	void getAllIndustries(AsyncCallback<List<Industry>> callback);

	void getIndustryDetails(int id, AsyncCallback<Industry> callback);

	void saveIndustryDetails(Industry jsp, AsyncCallback<Void> callback);

	void savePersonJSP(Personjsp personJSP, boolean deleteFirst,
			AsyncCallback<Void> callback);

	void isAdminUser(AsyncCallback<Boolean> callback);

	void getAllPersonEmploymentDetails(
			AsyncCallback<List<Employmentdetails>> callback);
	
	void getAllLogs (Date date, AsyncCallback<List<Logs>> callback);
}
